package org.wdcode.web.socket.server;

import org.wdcode.common.interfaces.Close;
import org.wdcode.web.socket.client.SocketClient;

/**
 * Socket服务器接口
 * @author WD
 * @since JDK6
 * @version 1.0 2009-09-14
 */
public interface SocketServer extends Close {
	/**
	 * 侦听并接受到此Socket的连接
	 * @return SocketClient
	 */
	SocketClient accept();

	/**
	 * 绑定到一台服务器上
	 * @param port 服务器端口
	 */
	void bind(int port);
}
